import { Controller, Delete, Get, Param, Post, Put } from "@nestjs/common";


@Controller('todos')
export class TodoController {

    @Get()
    getuser() {
        return '获取所有代办事项列表'
    }
    @Post()
    add() {
        return '创建新的代办事项'
    }
    @Get(':todold')
    todold(@Param('todold') todold: string): string {
        return `获取ID为${todold}的代办事项详情`;
    }
    @Put('update/:todold')
    update(@Param('todold') todold:string) {
        return `更新ID为${todold}的待办事项信息`

    }
    @Delete('delete/:todold')
    delete(@Param('todold') todold: string) {
        return `更新ID为${todold}的待办事项信息`

    }
}